﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Unity;

namespace Demo.Snake.Application.ViewModel
{
    public class ViewModels
    {
        private UnityContainer container = new UnityContainer(); //创建容器

        public ViewModels()
        {
            container.RegisterType<ShellViewModel>(); //注册依赖对象
        }

        public ShellViewModel ShellViewModel => container.Resolve<ShellViewModel>();
    }
}
